<?php

/**
 * A form used to change the max number of newnits of an account
 * @author panosbaroudjian
 *
 */
class Application_Form_ChangeMaxNewnits extends Zend_Form
{

    public function init()
    {
        /* Form Elements & Other Definitions Here ... */
        $this->setMethod('post');
        $field = new Zend_Form_Element_Text("max_newnits");
        $field->setLabel("At most, how many news do you want daily?");
        $validator = new Zend_Validate_GreaterThan("0");
        $field->addValidator($validator);
        $validator = new Zend_Validate_Int();
        $field->addValidator($validator);
        $this->addElement($field);
        $this->addElement('submit', 'changeMaxNewnitsSubmit', array('ignore' => true, 'label' => 'Save'));
    }
}

